/*
 * ProfessorSession
 * Professor Buisness APIs to sign/unsign for a class, update grade
 */
package edu.depaul.se.courseregistration.sessionbean;
import edu.depaul.se.courseregistration.jpa.schedule.CourseBeingTaught;
import edu.depaul.se.courseregistration.jpa.schedule.EnrolledClass;
import edu.depaul.se.courseregistration.jpa.user.Student;
import java.util.List;
import javax.ejb.EJB;
import javax.ejb.LocalBean;
import javax.ejb.Stateless;
/**
 *
 * @author Group2
 */
@Stateless
@LocalBean
public class ProfessorSession {
      @EJB
      ProfessorEJB professorEJB;
      
      //@Override
      public int signUpForClass(int sectionId, int personId){
        return professorEJB.signUpForClass(sectionId, personId);
    }
      
    //@Override
    public void unSignCourse(int sectionId, int personId){
           
        professorEJB.unSignCourse(sectionId, personId);
     }
    
    //@Override
    public void updateGrade(int  sectionId, int personId, String grade )
    {
       professorEJB.updateGrade(sectionId, personId, grade);
    }
    
    //Get all Student enrolled to a specific section Id
    //@Override
    public List < Student> getStudentList(int sectionId) {
     return professorEJB.getStudentList(sectionId);
    }
    //@Override
     public List < CourseBeingTaught > getSchedule(int personId){
      return professorEJB.getSchedule(personId);
    }
}
